package com.accounting.client.remote;

import java.util.List;

import com.accounting.client.remote.obj.PackageInfo;
import com.accounting.client.remote.transfer.AddPackageRequest;
import com.accounting.client.remote.transfer.SearchPackageRequest;
import com.accounting.client.remote.transfer.UpdatePackageRequest;
import com.google.gwt.user.client.rpc.AsyncCallback;

import corelib.client.search.PagingRequest;
import corelib.client.search.PagingResult;

public interface PackageServiceAsync {
	
	public void TrackPackage(String passport, String packageId, AsyncCallback<String> callback);
	public void RemovePackage(String passport, String packageId, AsyncCallback<Boolean> callback);
	public void RemovePackages(String passport, String reference, AsyncCallback<Boolean> callback);
	
	public void AddPackage(String passport, AddPackageRequest request, AsyncCallback<Boolean> callback);
	public void UpdatePackage(String passport, UpdatePackageRequest request, AsyncCallback<Boolean> callback);
	public void UpdatePackageStatus(String passport, String packageId, int status, AsyncCallback<Boolean> callback);
	public void UpdatePackageData(String passport, String packageId, String data, AsyncCallback<Boolean> callback);
	
	public void ListPackages(String passport, PagingRequest request, AsyncCallback<PagingResult<PackageInfo>> callback);
	public void ListPackagesByReference(String passport, String referenceId, AsyncCallback<List<PackageInfo>> callback);
	public void SearchPackages(String passport, SearchPackageRequest request, AsyncCallback<PagingResult<PackageInfo>> callback);
}
